Introduction
Today, I was facing one of the issues when installing electron using windows power shell, when I tried to install "electron, laravel" using Node Package Manager
Here is the error that I am facing today while installing the npm command in the windows power shell.
"npm: The term 'npm' is not recognized as the name of a cmdlet, function, scriptfile, or operable program. Check the spelling of the name, or if a path was
included, verify that the path is correct and try again.
At line:1 char:1
+ npm install electron --save-dev
+ ~~~
+ CategoryInfo : ObjectNotFound: (npm:String) [], CommandNotFoundExcept
ion
+ FullyQualifiedErrorId : CommandNotFoundException"
How to fix these issues:
In my case fellow things you need to do
- Missing Node.js software
- the old version of Node.js software
- Wrongly update Windows environment path
- Installed in the wrong path
You can easily download from here(https://nodejs.org/en/download/)
After downloading the setup next step is installing on your pc or laptop
Fellow the steps
- Run the setup file, the setup wizard will be open then click Next
- Accepting the term and conditions then click next.
- After that, You have seen the address where node.js will be installed on your pc click Next
- Click on Add to PATH => will be installed on the local hard drive and click Next
- Click Next and your setup is almost complete. Click the Finish button.
Updating the Path
Right-click on This pc or MY PC -> properties -> Advanced system settings -> environmental variable
click on edit -> Click New -> “C:\Program Files (x86)\nodejs” or “C:\Program Files \nodejs “.
After installation, automatically create a nodejs folder in this path “C:\Program Files (x86)” or “C:\Program Files “.
Open Control Panel -> User Accounts -> Change my environmental variable and verify the path variable value will be “C:\Program Files (x86)\nodejs” or “C:\Program Files \nodejs “.
If the path is wrong, you can edit to change the Windows directive.
After that Hopefully, you are able to fix these issues.
0 Comments